package org.luxor.common.netty.config.option;

/**
 * ssl证书配置
 *
 * @author Mr.yan @date 2023/12/15
 */
public class SslOption {

    /**
     * 数字证书文件 (PEM格式的X.509证书文件)
     */
    private String certFile;

    /**
     * 数字证书私钥文件 (PEM格式的PKCS#8私钥文件)
     */
    private String keyFile;

    /**
     * 数字证书书私钥文件的DES保护密码 (keyFile的密码，如果没有密码保护，则为空)
     */
    private String keyPassword;

    /**
     * CA根证书文件 (PEM格式的X.509证书文件. 为null时使用系统默认值.)
     */
    private String caCertFile;

    public SslOption() {
    }

    public SslOption(String certFile, String keyFile, String keyPassword, String caCertFile) {
        super();
        this.certFile = certFile;
        this.keyFile = keyFile;
        this.keyPassword = keyPassword;
        this.caCertFile = caCertFile;
    }

    public String getCertFile() {
        return certFile;
    }

    public void setCertFile(String certFile) {
        this.certFile = certFile;
    }

    public String getKeyFile() {
        return keyFile;
    }

    public void setKeyFile(String keyFile) {
        this.keyFile = keyFile;
    }

    public String getKeyPassword() {
        return keyPassword;
    }

    public void setKeyPassword(String keyPassword) {
        this.keyPassword = keyPassword;
    }

    public String getCaCertFile() {
        return caCertFile;
    }

    public void setCaCertFile(String caCertFile) {
        this.caCertFile = caCertFile;
    }
}
